/*
 * Copyright (c) 2004-2005 by Masoud Kalali [kalali@gmail.com]
 * http://www.jetnuke.org
 * 
 * 
 * This program is free software; you can redistribute it and/or modify it under
 * the terms of the GNU General Public License as published by the Free Software
 * Foundation; either version 2 of the License, or (at your option) any later
 * version.
 * 
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
 * details.
 * 
 * You should have received a copy of the GNU General Public License along with
 * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
 * Place - Suite 330, Boston, MA 02111-1307, USA.
 *  
 * Created on May 25, 2005
 */
package org.jetnuke.dao.postgresql;

import org.apache.log4j.Logger;

import java.sql.ResultSet;

import org.jetnuke.entities.OsCounter;

/**
 * @author Masoud Kalali
 * 
 */
public class PosgresqlOsCounterDAO extends
		org.jetnuke.dao.generic.GenericOsCounterDAO {
	/**
	 * Logger for this class
	 */
	private static final Logger logger = Logger
			.getLogger(PosgresqlOsCounterDAO.class);

	protected void fillOsCounterFromResultSet(OsCounter u, ResultSet rs)
			throws Exception {
		if (logger.isDebugEnabled()) {
			logger
					.debug("fillOsCounterFromResultSet(OsCounter, ResultSet) - start"); //$NON-NLS-1$
		}

		u.setCOUNTER(rs.getInt("COUNTER"));
		u.setOID(rs.getString("OIDN"));

		if (logger.isDebugEnabled()) {
			logger
					.debug("fillOsCounterFromResultSet(OsCounter, ResultSet) - end"); //$NON-NLS-1$
		}
	}
}
